package cn.xiaozhi0802.service.impl;

import cn.xiaozhi0802.dao.IAccountDao;
import cn.xiaozhi0802.domain.Account;
import cn.xiaozhi0802.service.IAccountService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author Administrator
 */
@Service("accountService")
public class AccountServiceImpl implements IAccountService {
    @Autowired
    private IAccountDao accountDao;
    @Override
    public void saveAccount(Account account) {
        accountDao.saveAccount(account);
    }

    @Override
    public List<Account> findAll() {
        System.out.println("业务层保存执行了..............");
        List<Account> all = accountDao.findAll();
        return all;
    }
}
